<include file="Public:header" />
<div id="zoneHeader">
    <h2>计划报表</h2>
    <ul>
        <li><button>操作按钮</button></li>
        <li><button>操作按钮</button></li>
        <li><button>操作按钮</button></li>
        <li><button>操作按钮</button></li>
        <li><button>操作按钮</button></li>
        <li><button>操作按钮</button></li>
    </ul>
</div><!--/#zoneHeader-->
<div id="zoneBody">
    <div id="zoneBodySearch">
        <form id="formSearch" action="?m={$Think.const.MODULE_NAME}">
            <input type="hidden" name="sort" />
            <input type="hidden" name="sortdir" />

            <ul>
                <li><b>日期：</b><input type="text" name="day" class="fW100p" /></li>
                <li><b>计划编号：</b><input type="text" name="plan_id" class="fW100p" /></li>
                <li><b>计划名称：</b><input type="text" name="plan_name" class="fW150p" /></li>
                <li>
                <select name="plan_type">
                    <option value="">计划类型</option>
                    <option value="cpc">CPC</option>
                    <option value="cpm">CPM</option>
                    <option value="cpv">CPV</option>
                </select>
                </li>
                <li rel="searchMoreItem">广告主编号：<input type="text" name="uid" style="width:100px" /></li>
                <li><button type="button" id="as" class="btnSearch">查询</button></li>
                <li><button type="reset" class="btnResetForm">清空表单</button></li>
                <li><label><input type="checkbox" class="btnSearchMore" /><span>高级查询</span></label></li>
            </ul>
        </form>
    </div><!--/#zoneBodySearch-->
    <div id="zoneBodyContent">
        <table class="table2">
            <thead>
                <tr>
                    <th>日期</th>
                    <th>计划名称</th>
                    <th>类型</th>
                    <th class="tAr"><a href="javascript:;" sort="view" class="sortItem">浏览量</a></th>
                    <th class="tAr"><a href="javascript:;" sort="num" class="sortItem">结算量</a></th>
                    <th class="tAr"><a href="javascript:;" sort="deduction" class="sortItem">扣点</a></th>
                    <th class="tAr"><a href="javascript:;" sort="click" class="sortItem">点/弹次数</a></th>
                    <th class="tAr"><a href="javascript:;" sort="do2_href_click" class="sortItem">二次点击</a></th>
                    <th class="tAr">CTR</th>
                    <th class="tAr"><a href="javascript:;" sort="ader_pay" class="sortItem">应收金额</a></th>
                    <th class="tAr"><a href="javascript:;" sort="siter_income" class="sortItem">应付金额</a></th>
                    <th class="tAr">盈利</th>
                    <th>操作</th>
                </tr>
            </thead>
            <tbody>
                <tr class="tAr">
                    <td colspan="3">所有页总计</td>
                    <td>{$allPageTotal.view}</td>
                    <td>{$allPageTotal.num}</td>
                    <td>{$allPageTotal.deduction}</td>
                    <td>{$allPageTotal.click}</td>
                    <td>{$allPageTotal.do2_href_click}</td>
                    <td>{:getCtr($allPageTotal['view'], $allPageTotal['num'])}%</td>
                    <td>{$allPageTotal.ader_pay}</td>
                    <td>{$allPageTotal.siter_income}</td>
                    <td>{:getProfit($allPageTotal['ader_pay'], $allPageTotal['siter_income'])}</td>
                    <td class="tAl"></td>
                </tr>
                <tr class="tAr">
                    <td colspan="3">当页合计</td>
                    <td>{$currPageTotal.view}</td>
                    <td>{$currPageTotal.num}</td>
                    <td>{$currPageTotal.deduction}</td>
                    <td>{$currPageTotal.click}</td>
                    <td>{$currPageTotal.do2_href_click}</td>
                    <td>{:getCtr($currPageTotal['view'], $currPageTotal['num'])}%</td>
                    <td>{$currPageTotal.ader_pay}</td>
                    <td>{$currPageTotal.siter_income}</td>
                    <td>{:getProfit($currPageTotal['ader_pay'], $currPageTotal['siter_income'])}</td>
                    <td class="tAl"></td>
                </tr>
                <volist name="page.record" id="vo">
                <tr class="tAr">
                    <td class="tAl">{$vo.day}</td>
                    <td class="tAl">#{$vo.plan_id} {$vo.plan_name}</td>
                    <td class="tAl">{$vo.plan_type|strtoupper}</td>
                    <td>{$vo.view}</td>
                    <td>{$vo.num}</td>
                    <td>{$vo.deduction}</td>
                    <td>{$vo.click}</td>
                    <td>{$vo.do2_href_click}</td>
                    <td>{:getCtr($vo['view'], $vo['num'])}%</td>
                    <td>{$vo.ader_pay}</td>
                    <td>{$vo.siter_income}</td>
                    <td>{:getProfit($vo['ader_pay'], $vo['siter_income'])}</td>
                    <td class="tAl">操作</td>
                </tr>
                </volist>
            </tbody>
        </table>
    </div><!--/#zoneBodyContent-->
</div><!--/#zoneBody-->
<div id="zoneFooter">{$page|uiGetPage}</div><!--/#zoneFooter-->
<include file="Public:footer" />
